// compile command: rustc --crate-type=lib rary.rs

// we can also use the attribute to let compiler making the rust sources to lib.
// if we uncomment the 2 lines below, we don't need to add --crate-type=lib option
// #![crate_type = "lib"]
// #![crate_name = "rary"]

pub fn public_function() {
    println!("called rary's `public_function()`");
}

fn private_function() {
    println!("called rary's `private_function()`");
}

pub fn indirect_access() {
    print!("called rary's `indirect_access()`, that\n> ");

    private_function();
}